Detail-in-context terrain displacement algorithm with optimizations

ABSTRACT

A method for generating a presentation of a region-of-interest in a terrain data representation for display on a display screen, comprising: translating each point of the representation within a lens bounds to a rotated plane being normal to a vector defined by a position for the region-of-interest with respect to a base plane for the representation and an apex above the base plane, the lens bounds defining a shoulder region at least partially surrounding a focal bounds defining a focal region in which the position is located, each point having a respective height above the base plane; displacing each translated point from the rotated plane by a function of the respective height and a magnification for the focal region, the magnification varying across the shoulder region in accordance with a drop-off function; rotating each displaced point toward a viewpoint for the region-of-interest to maintain visibility of each displaced point and each point of the data representation beyond the lens bounds when viewed from the viewpoint; and, adjusting each rotated point corresponding to the shoulder region to provide a smooth transition to the data representation beyond the lens bounds.

This application claims priority from U.S. Provisional Patent Application No. 60/670,646, filed Apr. 13, 2005, and incorporated herein by reference.

FIELD OF THE INVENTION

The invention relates to the field of computer graphics processing, and more specifically, to a method and system for generating detail-in-context lens presentations for terrain or elevation data.

BACKGROUND OF THE INVENTION

Display screens are the primary visual display interface for computers. One problem with display screens is that they are limited in size, thus presenting a challenge to user interface design, particularly when large amounts of visual information are to be displayed. This problem is often referred to as the “screen real estate problem”. Known tools for addressing this problem include panning and zooming. While these tools are suitable for a large number of display applications, they become less effective when sections of the visual information are spatially related, for example in layered maps and three-dimensional representations. In this type of visual information display, panning and zooming are not as effective as much of the context of the visual information may be hidden in the panned or zoomed display.

A more recent solution to the screen real estate problem involves the application of “detail-in-context” presentation techniques. Detail-in-context is the magnification of a particular region-of-interest (the “focal region” or “detail”) in a presentation while preserving visibility of the surrounding information (the “context”). This technique has applicability to the display of large surface area media (e.g., digital maps) on display screens of variable size including those of graphics workstations, laptop computers, personal digital assistants (“PDAs”), and cellular telephones.

In general, a detail-in-context presentation may be considered as a distorted view (or distortion) of a region-of-interest in an original image or representation where the distortion is the result of the application of a “lens” like distortion function to the original image. The lens distortion is typically characterized by magnification of a region-of-interest (the “focal region”) in an image where detail is desired in combination with compression of a region of the remaining information surrounding the region-of-interest (the “shoulder region”). The area of the image affected by the lens includes the focal region and the shoulder region. These regions define the perimeter of the lens. The shoulder region and the area surrounding the lens provide “context” for the “detail” in the focal region of the lens. The resulting detail-in-context presentation resembles the application of a lens to the image. A detailed review of various detail-in-context presentation techniques such as “Elastic Presentation Space” (“EPS”) may be found in a publication by Marianne S. T. Carpendale, entitled “A Framework for Elastic Presentation Space” (Carpendale, Marianne S. T., A Framework for Elastic Presentation Space (Burnaby, British Columbia: Simon Fraser University, 1999)), which is incorporated herein by reference.

Note that in the detail-in-context discourse, differentiation is often made between the terms “representation” and “presentation”. A representation is a formal system, or mapping, for specifying raw information or data that is stored in a computer or data processing system. For example, a digital map of a city is a representation of raw data including street names and the relative geographic location of streets and utilities. Such a representation may be displayed on a display screen or printed on paper. On the other hand, a presentation is a spatial organization of a given representation that is appropriate for the task at hand. Thus, a presentation of a representation organizes such things as the point of view and the relative emphasis of different parts or regions of the representation. For example, a digital map of a city may be presented with a region magnified to reveal street names.

One shortcoming of existing detail-in-context presentation methods is their inability to effectively distort terrain or other elevation data including digital elevations model (“DEM”) data. In general, a DEM is a representation of cartographic information in a raster, vector, or other data format. Typically, a DEM consists of a sampled array of elevations for a number of ground positions at regularly spaced intervals. The intervals may be, for example, 7.5-minute, 15-minute, 2-arc-second (also known as 30-minute), and 1-degree units. The 7.5- and 15-minute DEMs may be categorized as large-scale, 2-arc-second DEMs may be categorized as intermediate-scale, and 1-degree DEMs may be categorized as small-scale. Often, for example, the distortion of DEM data using existing detail-in-context methods will result in a detail-in-context presentation in which the viewer appears to be “underneath” the data.

A need therefore exists for an effective method and system for generating detail-in-context presentations for elevation or terrain data. Accordingly, a solution that addresses, at least in part, the above and other shortcomings is desired.

SUMMARY OF THE INVENTION

According to one aspect of the invention, there is provided a method for generating a presentation of a region-of-interest in a terrain data representation for display on a display screen, comprising: translating each point of the representation within a lens bounds to a rotated plane being normal to a vector defined by a position for the region-of-interest with respect to a base plane for the representation and an apex above the base plane, the lens bounds defining a shoulder region at least partially surrounding a focal bounds defining a focal region in which the position is located, each point having a respective height above the base plane; displacing each translated point from the rotated plane by a function of the respective height and a magnification for the focal region, the magnification varying across the shoulder region in accordance with a drop-off function; rotating each displaced point toward a viewpoint for the region-of-interest to maintain visibility of each displaced point and each point of the data representation beyond the lens bounds when viewed from the viewpoint; and, adjusting each rotated point corresponding to the shoulder region to provide a smooth transition to the data representation beyond the lens bounds.

The method may further include projecting each adjusted point within the shoulder region, each rotated point within the focal region, and each point of the representation beyond the lens bounds onto a plane in a direction aligned with the viewpoint to produce the presentation. The method may further include displaying the presentation on the display screen. The step of translating each point may further include determining a maximum translation for a point on the lens bounds and determining a translation for each point within the lens bounds by scaling the maximum translation in accordance with a distance of each point from the lens bounds. The function may be a product of the magnification and a difference between a magnitude of a vector defined by an origin of the representation with respect to the base plane and the viewpoint and the respective height. The step of rotating each displaced point may further include determining an axis of rotation for the rotating from a cross product of a vector defined by an origin of the representation with respect to the base plane and the viewpoint and a vector defined by the origin and the apex. The step of adjusting each rotated point corresponding to the shoulder region may further include adding to each rotated point a weighted average of first and second difference vectors scaled by the drop-off function, the first and second difference vectors corresponding to a difference between first and seconds points on the lens bound and corresponding first and second displaced points, respectively, the first and second points being on a line drawn through the rotated point. The method may further include approximating the representation with a mesh. And, the method may further include approximating the respective height using height information from surrounding points.

In accordance with further aspects of the present invention there are provided apparatus such as a data processing system, a method for adapting this system, as well as articles of manufacture such as a computer readable medium having program instructions recorded thereon for practising the method of the invention.

BRIEF DESCRIPTION OF THE DRAWINGS

Further features and advantages of the embodiments of the present invention will become apparent from the following detailed description, taken in combination with the appended drawings, in which:

FIG. 1 is a graphical representation illustrating the geometry for constructing a three-dimensional perspective viewing frustum, relative to an x, y, z coordinate system, in accordance with elastic presentation space graphics technology and an embodiment of the invention;

FIG. 2 is a graphical representation illustrating the geometry of a presentation in accordance with elastic presentation space graphics technology and an embodiment of the invention;

FIG. 3 is a block diagram illustrating a data processing system adapted for implementing an embodiment of the invention;

FIG. 4 is a graphical representation illustrating the geometry of a terrain dataspace and an apex-aligned vector in accordance with an embodiment of the invention;

FIG. 5 is a graphical representation illustrating the geometry of a portion of the base plane in which the terrain dataset is defined and which is rotated such that it remains perpendicular to the apex-aligned vector in accordance with an embodiment of the invention;

FIG. 6 is a graphical representation illustrating the geometry for finding the maximum translation value for a point using similar triangles in accordance with an embodiment of the invention;

FIG. 7 is a graphical representation illustrating the geometry of a projection for finding the scaling factor that is used in the calculation of the magnitude of translation for a point in accordance with an embodiment of the invention;

FIG. 8 is a graphical representation illustrating the geometry of the result of the pseudo-rotation and displacement of each point that falls within the lens bounds in accordance with an embodiment of the invention;

FIG. 9 is a graphical representation illustrating the geometry of the rotation towards the view reference point of each point that falls within the lens bounds in accordance with an embodiment of the invention;

FIG. 10 is a graphical representation illustrating the geometry of a discontinuity occurring between the shoulder region and the context data after the application of the displacement and rotation transformations in accordance with an embodiment of the invention;

FIG. 11 is a graphical representation illustrating the geometry of the projection of the two dimensional version of a point onto the axis of rotation and the resulting edge points in accordance with an embodiment of the invention;

FIG. 12 is a graphical representation illustrating the geometry of the final lens resulting from the displacement of terrain data that fell within the lens bounds in accordance with an embodiment of the invention; and,

FIG. 13 is a flow chart illustrating operations of modules within the memory of a data processing system for generating a presentation of a region-of-interest in a terrain data representation for display on a display screen, in accordance with an embodiment of the application.

It will be noted that throughout the appended drawings, like features are identified by like reference numerals.

DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS

In the following description, details are set forth to provide an understanding of the invention. In some instances, certain software, circuits, structures and methods have not been described or shown in detail in order not to obscure the invention. The term “data processing system” is used herein to refer to any machine for processing data, including the computer systems and network arrangements described herein. The present invention may be implemented in any computer programming language provided that the operating system of the data processing system provides the facilities that may support the requirements of the present invention. Any limitations presented would be a result of a particular type of operating system or computer programming language and would not be a limitation of the present invention.

As mentioned above, a detail-in-context presentation may be considered as a distorted view (or distortion) of a portion of the original representation or image where the distortion is the result of the application of a “lens” like distortion function to the original representation. In general, detail-in-context data presentations are characterized by magnification of areas of an image where detail is desired, in combination with compression of a restricted range of areas of the remaining information, the result typically giving the appearance of a lens having been applied to the display surface. Using the techniques described by Carpendale, points in a representation are displaced in three dimensions and a perspective projection is used to display the points on a two-dimensional presentation display. Thus, when a lens is applied to a two-dimensional continuous surface representation, for example, the resulting presentation appears to be three-dimensional. In other words, the lens transformation appears to have stretched the continuous surface in a third dimension. In EPS graphics technology, a two-dimensional visual representation is placed onto a surface; this surface is placed in three-dimensional space; the surface, containing the representation, is viewed through perspective projection; and the surface is manipulated to effect the reorganization of image details. The presentation transformation is separated into two steps: surface manipulation or distortion and perspective projection.

FIG. 1 is a graphical representation illustrating the geometry 100 for constructing a three-dimensional (“3D”) perspective viewing frustum 220, relative to an x, y, z coordinate system, in accordance with elastic presentation space (EPS) graphics technology and an embodiment of the invention. In EPS technology, detail-in-context views of two-dimensional (“2D”) visual representations are created with sight-line aligned distortions of a 2D information presentation surface within a 3D perspective viewing frustum 220. In EPS, magnification of regions of interest and the accompanying compression of the contextual region to accommodate this change in scale are produced by the movement of regions of the surface towards the viewpoint (“VP”) 240 located at the apex of the pyramidal shape containing the frustum 220. The process of projecting these transformed layouts via a perspective projection results in a new 2D layout which includes the zoomed and compressed regions. The use of the third dimension and perspective distortion to provide magnification in EPS provides a meaningful metaphor for the process of distorting the information presentation surface. The 3D manipulation of the information presentation surface in such a system is an intermediate step in the process of creating a new 2D layout of the information.

FIG. 2 is a graphical representation illustrating the geometry 200 of a presentation in accordance with EPS graphics technology and an embodiment of the invention. EPS graphics technology employs viewer-aligned perspective projections to produce detail-in-context presentations in a reference view plane 201 which may be viewed on a display. Undistorted 2D data points are located in a base plane 210 of a 3D perspective viewing volume or frustum 220 which is defined by extreme rays 221 and 222 and the base plane 210. The VP 240 is generally located above the centre point of the base plane 210 and reference view plane (“RVP”) 201. Points in the base plane 210 are displaced upward onto a distorted surface or “lens” 230 which is defined by a general 3D distortion function (i.e., a detail-in-context distortion basis function). The direction of the viewer-aligned perspective projection corresponding to the distorted surface or lens 230 is indicated by the line FPo-FP 231 drawn from a point FPo 232 in the base plane 210 through the point FP 233 which corresponds to the focal point, focus, or focal region 233 of the distorted surface or lens 230. Typically, the perspective projection has a uniform direction 231 that is viewer-aligned (i.e., the points FPo 232, FP 233, and VP 240 are collinear).

EPS is applicable to multidimensional data and is well suited to implementation on a computer for dynamic detail-in-context display on an electronic display surface such as a monitor. In the case of two dimensional data, EPS is typically characterized by magnification of areas of an image where detail is desired 233, in combination with compression of a restricted range of areas of the remaining information (i.e., the context) 234, the end result typically giving the appearance of a lens 230 having been applied to the display surface. The areas of the lens 230 where compression occurs may be referred to as the “shoulder” or shoulder region 234 of the lens 230. The area of the representation transformed by the lens may be referred to as the “lensed area”. The lensed area thus includes the focal region 233 and the shoulder region 234. To reiterate, the source image or representation to be viewed is located in the base plane 210. Magnification 233 and compression 234 are achieved through elevating elements of the source image relative to the base plane 210, and then projecting the resultant distorted surface onto the reference view plane 201. EPS performs detail-in-context presentation of n-dimensional data through the use of a procedure wherein the data is mapped into a region in an (n+1) dimensional space, manipulated through perspective projections in the (n+1) dimensional space, and then finally transformed back into n-dimensional space for presentation. EPS has numerous advantages over conventional zoom, pan, and scroll technologies, including the capability of preserving the visibility of information outside 210, 234 the local region of interest 233.

For example, and referring to FIGS. 1 and 2, in two dimensions, EPS can be implemented through the projection of an image onto a reference plane 201 in the following manner. The source image or representation is located on a base plane 210, and those regions of interest 233 of the image for which magnification is desired are elevated so as to move them closer to a reference plane situated between the reference viewpoint 240 and the reference view plane 201. Magnification of the focal region 233 closest to the RVP 201 varies inversely with distance from the RVP 201. As shown in FIGS. 1 and 2, compression of regions 234 outside the focal region 233 is a function of both distance from the RVP 201, and the gradient of the function (i.e., the shoulder function or drop-off function) describing the vertical distance from the RVP 201 with respect to horizontal distance from the focal region 233. The resultant combination of magnification 233 and compression 234 of the image as seen from the reference viewpoint 240 results in a lens-like effect similar to that of a magnifying glass applied to the image. Hence, the various functions used to vary the magnification and compression of the source image via vertical displacement from the base plane 210 are described as lenses, lens types, or lens functions. Lens functions that describe basic lens types with point and circular focal regions, as well as certain more complex lenses and advanced capabilities such as folding, have previously been described by Carpendale.

FIG. 3 is a block diagram of a data processing system 300 adapted to implement an embodiment of the invention. The data processing system 300 is suitable for implementing EPS technology and for generating detail-in-context presentations of elevation data representations. The data processing system 300 includes an input device 310, a central processing unit (“CPU”) 320, memory 330, and a display 340. The input device 310 may include a keyboard, mouse, trackball, or similar device. The CPU 320 may include dedicated coprocessors and memory devices. The memory 330 may include RAM, ROM, databases, or disk devices. And, the display 340 may include a computer screen, terminal device, or a hard-copy producing output device such as a printer or plotter. The data processing system 300 has stored therein data representing sequences of instructions which when executed cause the method described herein to be performed. Of course, the data processing system 300 may contain additional software and hardware a description of which is not necessary for understanding the invention.

Thus, the data processing system 300 includes computer executable programmed instructions for directing the system 300 to implement the embodiments of the present invention. The programmed instructions may be embodied in one or more hardware or software modules 331 resident in the memory 330 of the data processing system 300. Alternatively, the programmed instructions may be embodied on a computer readable medium (such as a CD disk or floppy disk) which may be used for transporting the programmed instructions to the memory 330 of the data processing system 300. Alternatively, the programmed instructions may be embedded in a computer-readable, signal or signal-bearing medium that is uploaded to a network by a vendor or supplier of the programmed instructions, and this signal or signal-bearing medium may be downloaded through an interface to the data processing system 300 from the network by end users or potential buyers.

As mentioned, detail-in-context presentations of data using techniques such as pliable surfaces, as described by Carpendale, are useful in presenting large amounts of information on display surfaces of variable size. Detail-in-context views allow magnification of a particular region-of-interest (the “focal region”) 233 in a data presentation while preserving visibility of the surrounding information 210.

Now, referring to FIG. 12, the present invention provides a method for viewing a region-of-interest (e.g., at 480) within terrain data 450 using a detail-in-context lens 1210. A terrain dataset 450 is assumed to consist of a set of (x, y, z) coordinates, where the (x, y) coordinates denote a position on the earth, and the z coordinate specifies the elevation of the earth at the (x, y) position. The detail-in-context lens 1210 is assumed to have a circular focal region 1220 (although it may have any other shape) and a shoulder region 1230 defined by a finite drop-off function or shoulder function. The method of the present invention allows a user to apply a detail-in-context terrain lens 1210 to a terrain dataset 450, and view the terrain data from any point above the terrain surface. As the viewpoint vrp moves, the terrain lens 1210 is altered such that the terrain data that is in the focal region 1220 of the lens 1210 is always in view. The method of the present invention includes the steps described below which refer to FIGS. 4-12.

FIG. 4 is a graphical representation illustrating the geometry 400 of a terrain dataspace 470 and an apex-aligned vector 460 in accordance with an embodiment of the invention. FIG. 4 shows the definition of the terrain dataspace 470 and the apex-aligned vector 460.

Step 1: Define the terrain dataspace 470 in which the terrain dataset 450 is viewed. The terrain dataspace 470 consists of a perspective viewing volume 471 that is defined by an apex (or camera position) 440 and a viewing frustum 420. The terrain dataset 450 is defined with respect to the z=0 base plane 410 (i.e., the x, y plane). A user can view the terrain dataset 450 from any point above the terrain surface 410 . The viewpoint is referred to as the view reference point vrp in FIG. 4.

Step 2: Calculate the apex-aligned vector 460. The apex-aligned vector 460 is a vector from the three-dimensional lens position 480 to the apex 440 of the viewing frustum 420. The x, y coordinates of the three-dimensional lens position 480 are defined by the user in the z=0 plane. The z coordinate of the lens position 480 is found by approximation using the surrounding terrain dataset 450 elevation values. The method of approximation is described in more detail in the optimizations section below. Mathematically, the apex-aligned vector is defined as a=apex−lenspos, where apex is the apex 440 of the viewing frustum 420 and lenspos is the three-dimensional lens position 480. FIG. 4 illustrates the definition of the apex-aligned vector 460.

FIG. 5 is a graphical representation illustrating the geometry 500 of a portion 510 of the base plane 410 in which the terrain dataset 450 is defined and which is rotated such that it remains perpendicular to the apex-aligned vector 460 in accordance with an embodiment of the invention.

Step 3: Rotate each point of the dataset 450 that falls within the lens bounds 482 such that a corresponding portion 510 of the base plane 410 in which the terrain dataset 450 is defined remains perpendicular to the apex-aligned vector 460. As stated above, the terrain dataset 450 is defined with respect to the z=0 plane. As the lens position 480 is moved, the apex-aligned vector 460 will no longer be perpendicular to the z=0 plane (see FIG. 5). In order to maintain the spatial relationship of the points that fall within the lens bounds 482 during the detail-in-context displacement, the portion 510 of the base plane 410 in which the terrain dataset 450 is defined is rotated such that it remains perpendicular to the apex-aligned vector 460.

Each point of the dataset 450 within the lens bounds 482 is rotated by an appropriate amount such that each point maintains its perpendicular spatial relationship with respect to the apex-aligned vector 460. Since the displacement algorithm utilizes a perspective viewing volume 471, and the terrain dataset 450 is assumed to be viewed through the perspective viewing volume 471, the rotation of each point is specified as a translation instead of using a rotation matrix. This is due to the fact that, when viewed through a perspective viewing volume 471, objects do not visually maintain their shapes as they are rotated about arbitrary axes. For example, a circle that is defined in the z=0 plane within a viewing frustum that has an apex defined along the positive z axis will visually become an oval when rotated about the x or y axes. In order to maintain the visual shape of the lens and focal region, each point within the lens bounds 482 is translated an appropriate distance along the apex-aligned vector 460. This ensures that the bounds 482 of the lens remain visually constant as the lens is moved around the dataspace 470. The calculations for determining the amount of translation for each point that falls within the lens bounds 482 are described in the following.

FIG. 6 is a graphical representation illustrating the geometry 600 for finding the maximum translation value 610 for a point using similar triangles in accordance with an embodiment of the invention.

Step 3a: Calculate the maximum translation 610 that can occur. The pseudo-rotation of the points within a lens bounds 482 occurs about an axis of rotation. The axis of rotation can be found by taking the cross-product of the unit vector (0,0,1) with the apex-aligned vector 460 or a, that is, (0,0,1)×a=axis.

The maximum translation 610 occurs for the points (when taken with respect to the centre of the lens 480) that are on the lens bounds 482 and that are perpendicular to the axis of rotation. Mathematically, a point p for which maximum translation occurs is a point for which the following equation holds true: (p−lenspos)·axis=0, when p is on the lens bounds 482. The maximum translation 610 that can occur for a point p is found and is used to interpolate the translation values for all points interior to the lens bounds 482.

The maximum translation value 610 is found by taking a point p that is perpendicular to the axis of rotation (as stated above), and projecting it onto the rotated plane (see FIG. 6). The distance from the original point p to the projected point p_(projected) is the maximum translation value 610. As shown in FIG. 6, similar triangles can be used to find the maximum translation value for a point p. Mathematically, the maximum translation value maxt 610 is as follows: maxt−∥(0,0,radius)−proj ((0,0,radius), a)∥, where a is the apex-aligned vector 460, radius or r is the radius of the lens bounds 482, and the function proj(i, j) returns the projection of vector i onto vector j.

FIG. 7 is a graphical representation illustrating the geometry 700 of a projection for finding the scaling factor that is used in the calculation of the magnitude of translation for a point p in accordance with an embodiment of the invention.

Step 3b: Calculate the magnitude of the translation for each point p. To find the magnitude of the translation for each point p, the apex-aligned vector a or 460 is projected onto the z=0 plane which results in a two-dimensional vector a_(2D) (i.e., where the z coordinate is 0). This is equivalent to taking the x and y coordinates, and disregarding the z coordinate: a_(2D)=(a_(x), a_(y)). The a_(2D) vector is then normalized. Each point p within the lens bounds 482 is projected onto the z=0 plane (but no normalization occurs), and is specified as a vector with respect to the centre of the lens lenspos or 480: p_(2D)=(p_(x), p_(y))−(lenspos_(x), lenspos_(y)). The vectors a_(2D) and p_(2D) are used to find a scaling factor 25 that will scale the maximum translation value maxt 610, which will result in the magnitude of translation for the point p. The scaling factor scale_(p) is found by projecting p_(2D) onto a_(2D), and taking the magnitude of the resulting vector (see FIG. 7): scale_(p)=∥proj (p_(2D), a_(2D))∥. The magnitude of translation trans_(p) of the point p is the maximum translation value 610 scaled by the scaling factor scale_(p): trans_(p)=(−scale_(p)/radius)*maxt, where radius is the radius r of the lens bounds 482.

Step 3c: Translate each point p with respect to the lens position 480. Each point p is translated with respect to the lens position 480 in order to maintain the spatial relationships between points. Therefore, each point p is projected onto the plane that contains the lens position point 480 and that is parallel to the z=0 plane. Once the point has been projected onto this plane, the point is translated along the apex-aligned vector a or 460, by a magnitude of translation trans_(p): p_(translated)=(p_(x), p_(y), lenspos_(z))+trans_(p)*a_(normalized), where a_(normalized) is the unit apex-aligned vector. Since the elevation value of the point was eliminated when the point was projected onto the plane that contains the lens position 480, the elevation value must be added back to the point: p_(translated)=p_(translated)+(p_(z)−lenspos_(z))*a_(normalized).

Step 4: Displace each point p by the appropriate magnification factor. As shown in FIG. 4, a user can view the terrain dataset 450 from any point vrp above the terrain surface. Since the displacement of each point p should not exceed the vrp, the magnitude of displacement is computed with respect to the vrp. The magnitude of displacement takes into consideration the original elevation height of a point p and is computed using the equation height_(p)=h−(h/mag), where mag is the desired magnification of the lens, h=∥vo∥−p_(z), and vo is the vector from the origin of the dataspace 490 in which the terrain data 450 is defined to the vrp. If the point p is within the shoulder region of the lens (i.e., between the focal bounds 481 and the lens bounds 482), then the magnitude of displacement must be scaled by the shoulder drop-off function: height_(p)=shoulder(p)*(h−(h/mag)).

FIG. 8 is a graphical representation illustrating the geometry 800 of the result of the pseudo-rotation and displacement of each point p that falls within the lens bounds 482 in accordance with an embodiment of the invention. The displacement of a point p is performed using the translated point p_(translated) that was found above and adding the height value height_(p) along the z-normalized apex-aligned vector: p_(displaced)=p_(translated)+height_(p)*a_(znormalized). The result of the displacement of all points p within the lens bounds 482, that is, the displaced data or lens 810, is shown in FIG. 8.

FIG. 9 is a graphical representation illustrating the geometry 900 of the rotation towards the vrp of each point p that falls within the lens bounds 482 in accordance with an embodiment of the invention. In FIG. 9, the angle and axis of rotation are computed using the ao and vo vectors.

Step 5: Rotate the lens 810 towards the view reference point vrp. Since the terrain dataset 450 can be viewed from any point vrp above the terrain surface, it would be useful to be able to see the lens focal region (i.e., the region between the lens position 480 and the focal bounds 481) at all times from the viewpoint. To accomplish this, each point p that falls within the lens bounds 482 is rotated towards the vrp. Given the origin o or 490 of the dataspace 470 in which the terrain data 450 is defined, two vectors ao=(apex−o)_(normalized) and vo=(vrp−o)_(normalized) are defined. The axis of rotation is computed using the cross-product of the two vectors axis=ao×vo, and the angle of rotation is θ=arccos(ao·vo) (see FIG. 9). Quaternions are used to rotate each point p_(displaced) of the displaced data 810 by an angle θ about the axis of rotation axis which yields the desired rotated point p_(rotated).

FIG. 10 is a graphical representation illustrating the geometry 1000 of a discontinuity 1030 occurring between the shoulder region 1010 and the context data 450 after the application of the displacement and rotation transformations in accordance with an embodiment of the invention.

Step 6: Create smooth shoulders 1010 that are connected to the context data 450. After displacement and rotation, the shoulders 1010 of the lens 810 do not line up correctly with the context data 450 (i.e., points that fall outside of the lens bounds 482). FIG. 10 illustrates the resulting discontinuities 1030. In order to connect the shoulders 1010 to the context 450 (i.e., the terrain data 450 beyond the lens bounds 482), each point p that falls within the shoulder 1010 of the lens 810 will be translated an appropriate amount which will compensate for the discontinuity 1030. The following steps are used to find the magnitude and direction of translation for a point p that falls within the shoulder 1010 of the lens 810.

Step 6a: Find the axis of rotation that a point p was rotated about. Each point p that falls within the shoulder 1010 of the lens 810 has undergone two rotation transformations (i.e., the pseudo-rotation towards the apex and the rotation towards the vrp). The axes of rotation for these two transformations may have been different. In other words, the rotation of any given point p is the result of two separate rotations. These two rotations can be expressed as a single rotation about a vector axis resulting from the cross product of ao and v (i.e., axis=ao×v ). The vector ao is defined above and the vector v=p_(rotated)−p.

FIG. 11 is a graphical representation illustrating the geometry 1100 of the projection of p_(2D) onto the axis of rotation and the resulting edge points in accordance with an embodiment of the invention.

Step 6b: Project the point p onto the axis of rotation. The two-dimensional version of the point p was defined above as p_(2D)=(p_(x), p_(y))−(lenspos_(x), lenspos_(y)). The vector p_(2D) is projected onto the two-dimensional version of the axis of rotation axis_(2D) (see FIG. 11), or, p_(projected)=proj (p_(2D), axiS_(2D)).

Step 6c: Find two points that are on the edge of the lens bounds 482 that form a line through p_(projected) that is perpendicular to axis_(2D). In order to find two edge points that correspond to this definition, the equation of a line is used pt=pt_(o)+td, where pt_(o)=p_(projected), and the direction vector is defined as d=(p_(2D)−p_(projected))/∥(p_(2D)−p_(projected))∥. The parameter t can be found using Pythagorean's Theorem: t=√(radius²−∥p_(projected)∥²) where radius or r is the radius of the lens bounds 482. Two edge points pt1 _(2D) and pt2 _(2D) are found by using ±t in the line equation. The z elevation coordinates of these two points are found using the approximation method that is described in the optimizations section below, yielding the three-dimensional edge points pt1 and pt2.

Step 6d: Apply rotation and displacement transformations to each edge point pt1, pt2 and find the difference vectors diff₁, diff₂ between the original and transformed edge points. Each edge point will undergo the pseudo-rotation, displacement, and final rotation transformations that are specified in Steps 2-5 above in order to obtain the difference between the original edge points (pt1 and pt2) and the transformed edge points (pt1 _(transformed) and pt2 _(transformed), respectively). This difference specifies the magnitude and direction of translation that the edge points will undergo, which will essentially connect the lens shoulder region 1010 back to the context data 450. The difference vectors for each edge are used as a weighted average to find the amount of translation that is needed for points p that are interior to the lens bounds 282 (i.e., points that do not fall on the lens bounds 282 but rather fall between the lens bounds 282 and the focal bounds 481).

FIG. 12 is a graphical representation illustrating the geometry 1200 of the final lens 1210 resulting from the displacement of terrain data 450 that fell within the lens bounds 482 in accordance with an embodiment of the invention.

Step 6e: Calculate the amount of translation for a point p to obtain smooth shoulders 1010. The difference vectors diff₁ and diff₂ that were found for each edge point are used as a weighted average to find the amount of translation for a point p. The weight w for diff₂ is given by w=∥(p_(x), p_(y))=pt2 _(2D)∥/∥Pt1 _(2D)−pt2 _(2D)∥, where pt1 _(2D) and pt2 _(2D) are as defined above. The difference vector diff_(p) for point p is diff_(p)=(1−shoulder (p)) ((1−w) diff₁+w diff₂), where shoulder(p) is the shoulder drop-off function. Since the weighted average is taken across the entire bounds of the lens, and since the points that fall within the focal region 1040 of the lens 810 should not be translated (i.e., only the shoulders 1010 of the lens 810 are altered), the difference vector must take into consideration the focal region 1040 of the lens 810. For this reason, the factor (1−shoulder (p)) is introduced. The final displacement of a point p is p_(displaced)=p_(rotated)+diff_(p). FIG. 12 shows a cross section of the final result 1210 of the displacement of terrain data that fell within the lens bounds 482. Note that the resulting lens 1210 has shoulders 1230 surrounding the focal region 1220 that smoothly join the surrounding context 450 (i.e., the terrain data 450 beyond the lens bounds 482).

The optimizations referred to above are described in the following.

Terrain Lens Mesh. The terrain datasets 450 that are used in terrain visualization are often very large in size, consisting of thousands of data points. When this is the case, due to processing limitations, it may not be feasible to run each point through the terrain displacement method described above. To increase efficiency of the method, a terrain lens mesh may be used to visualize the displacement of a terrain lens 1210. The mesh bounds are defined as the bounds 482 of the lens 1210. Two-dimensional points are inserted into the mesh and a Delauney triangulation is calculated. In order to visualize the terrain elevations, the z elevation of each point is approximated using the surrounding terrain dataset elevation values as described below. Once the z elevations for each point within the mesh have been approximated, each three-dimensional mesh point can be run through the terrain displacement method described above.

Elevation Approximations. Since terrain elevation datasets 450 are discrete and finite, any given coordinate that is within the bounds of the terrain dataset may not have an explicit elevation value associated with it. Therefore, within the terrain displacement method and the terrain lens mesh optimization both described above, an approximation for the z elevation for any given (x, y) coordinate may be used. This approximation uses the surrounding terrain dataset coordinates to compute the estimated elevation for an (x, y) coordinate. The terrain dataset coordinates can be random or ordered, but ordered points (such as a grid structure) will increase efficiency of the approximation algorithm. According to one embodiment, a bilinear approximation may be used given a grid structured terrain dataset. That is, given an (x, y) coordinate, its elevation may be approximated by finding the four enclosing grid coordinates that surround the (x, y) coordinate. Then, a bilinear interpolation is computed using the four elevation values associated with the four enclosing grid coordinates.

The above described method may be summarized with the aid of a flowchart. FIG. 13 is a flow chart illustrating operations 1300 of modules 331 within the memory 330 of a data processing system 300 for generating a presentation of a region-of-interest (e.g., at 480) in a terrain data representation 450 for display on a display screen 340, in accordance with an embodiment of the application.

At step 1301, the operations 1300 start.

At step 1302, each point p of the representation 450 within a lens bounds 482 is translated to a rotated plane 510 being normal to a vector 460 defined by a position 480 for the region-of-interest with respect to a base plane 410 for the representation 450 and an apex 440 above the base plane 410, the lens bounds 482 defining a shoulder region (i.e., between 482 and 481) at least partially surrounding a focal bounds 481 defining a focal region (i.e., between 481 and 480) in which the position 480 is located, each point p having a respective height pz above the base plane 410.

At step 1303, each translated point p_(translated) is displaced from the rotated plane 510 by a function height_(p) of the respective height p_(z) and a magnification mag for the focal region 481, 482, the magnification mag varying across the shoulder region 481, 482 in accordance with a drop-off function shoulder(p).

At step 1304, each displaced point p_(displaced) is rotated toward a viewpoint vrp for the region-of-interest to maintain visibility of each displaced point p_(displaced) and each point p of the data representation 450 beyond the lens bounds 482 when viewed from the viewpoint vrp.

At step 1305, each rotated point p_(rotated) corresponding to the shoulder region 481, 482 is adjusted to provide a smooth transition 1230 to the data representation 450 beyond the lens bounds 482.

At step 1306, the operations 1300 end.

The method may further include projecting each adjusted point p_(rotated)+diff_(p) within the shoulder region 1230, each rotated point p_(rotated) within the focal region 1220, and each point p of the representation 450 beyond the lens bounds 482 onto a plane 201 in a direction 231 aligned with the viewpoint vrp to produce the presentation. The method may further include displaying the presentation on the display screen 340. The step of translating 1302 each point p may further include determining a maximum translation maxt 610 for a point p on the lens bounds 482 and determining a translation trans_(p) for each point p within the lens bounds (i.e., between 482 and 480) by scaling the maximum translation 610 in accordance with a distance scale_(p)/radius of each point from the lens bounds 482. The function height_(p) may be a product of the magnification mag and a difference h between a magnitude of a vector∥vo∥ defined by an origin 490 of the representation 450 with respect to the base plane 410 and the viewpoint vrp and the respective height p_(z). The step of rotating 1304 each displaced point p_(displaced) may further include determining an axis of rotation axis for the rotating from a cross product of a vector ao defined by an origin 490 of the representation 450 with respect to the base plane 410 and the viewpoint vrp and a vector vo defined by the origin 290 and the apex apex 440. The step of the adjusting 1305 each rotated point p_(rotated) corresponding to the shoulder region 481, 482 may further include adding to each rotated point p_(rotated) a weighted average diff_(p)=(1−shoulder (p)) ((1−w) diff₁+w diff₂) of first and second difference vectors diff₁, diff₂ scaled by the drop-off function, the first and second difference vectors diff₁, diff₂ corresponding to a difference between first and seconds points pt1, pt2 on the lens bound 482 and corresponding first and second displaced points pt1 _(transformed), pt2 _(transformed), respectively, the first and second points pt1, pt2 being on a line pt=pt_(o)+td drawn through the rotated point p_(rotated). The method may further include approximating the representation 450 with a mesh. And, the method may further include approximating the respective height p_(z) using height information from surrounding points.

While this invention is primarily discussed as a method, a person of ordinary skill in the art will understand that the apparatus discussed above with reference to a data processing system 300, may be programmed to enable the practice of the method of the invention. Moreover, an article of manufacture for use with a data processing system 300, such as a pre-recorded storage device or other similar computer readable medium including program instructions recorded thereon, may direct the data processing system 300 to facilitate the practice of the method of the invention. It is understood that such apparatus and articles of manufacture also come within the scope of the invention.

In particular, the sequences of instructions which when executed cause the method described herein to be performed by the exemplary data processing system 300 of FIG. 3 can be contained in a data carrier product according to one embodiment of the invention. This data carrier product can be loaded into and run by the exemplary data processing system 300 of FIG. 3. In addition, the sequences of instructions which when executed cause the method described herein to be performed by the exemplary data processing system 300 of FIG. 3 can be contained in a computer software product according to one embodiment of the invention. This computer software product can be loaded into and run by the exemplary data processing system 300 of FIG. 3. Moreover, the sequences of instructions which when executed cause the method described herein to be performed by the exemplary data processing system 300 of FIG. 3 can be contained in an integrated circuit product (e.g., a hardware module) including a coprocessor or memory according to one embodiment of the invention. This integrated circuit product can be installed in the exemplary data processing system 300 of FIG. 3.

The embodiments of the invention described above are intended to be exemplary only. Those skilled in the art will understand that various modifications of detail may be made to these embodiments, all of which come within the scope of the invention. 

What is claimed is:
 1. A method for generating a presentation of a region-of-interest in a terrain data representation for display on a display screen of a data processing system, comprising: translating each point of the representation, by the data processing system, within a lens bounds to a rotated plane being normal to a vector defined by a position for the region-of-interest with respect to a base plane for the representation and an apex above the base plane, the lens bounds defining a shoulder region at least partially surrounding a focal bounds defining a focal region in which the position is located, each point having a respective height above the base plane; displacing each translated point from the rotated plane, by the data processing system, by a function of the respective height and a magnification for the focal region, the magnification varying across the shoulder region in accordance with a drop-off function; rotating each displaced point, by the data processing system, toward a viewpoint for the region-of-interest to maintain visibility of each displaced point; and adjusting each rotated point corresponding to the shoulder region, by the data processing system, to provide a smooth transition to the data representation beyond the lens bounds.
 2. The method of claim 1 and further comprising projecting each adjusted point within the shoulder region, each rotated point within the focal region, and each point of the representation beyond the lens bounds onto a plane in a direction aligned with the viewpoint to produce the presentation.
 3. The method of claim 2 and further comprising displaying the presentation on the display screen.
 4. The method of claim 3 wherein the translating of each point further comprises determining a maximum translation for a point on the lens bounds and determining a translation for each point within the lens bounds by scaling the maximum translation in accordance with a distance of each point from the lens bounds.
 5. The method of claim 3 wherein the function is a product of the magnification and a difference between a magnitude of a vector defined by an origin of the representation with respect to the base plane and the viewpoint and the respective height.
 6. The method of claim 3 wherein the rotating of each displaced point further comprises determining an axis of rotation for the rotating from a cross product of a vector defined by an origin of the representation with respect to the base plane and the viewpoint and a vector defined by the origin and the apex.
 7. The method of claim 3 wherein the adjusting of each rotated point corresponding to the shoulder region further comprises adding to each rotated point a weighted average of first and second difference vectors scaled by the drop-off function, the first and second difference vectors corresponding to a difference between first and seconds points on the lens bound and corresponding first and second displaced points, respectively, the first and second points being on a line drawn through the rotated point.
 8. The method of claim 1 and further comprising approximating the representation with a mesh.
 9. The method of claim 1 and further comprising approximating the respective height using height information from surrounding points.
 10. A system comprising: a processor; and a module that is executable on the processor for translating each point of a terrain data representation within a lens bounds of a presentation of a region-of-interest, for display on a display screen, to a rotated plane being normal to a vector defined by a position for the region-of-interest with respect to a base plane for the representation and an apex above the base plane, the lens bounds defining a shoulder region at least partially surrounding a focal bounds defining a focal region in which the position is located, each point having a respective height above the base plane; a module that is executable on the processor for displacing each translated point from the rotated plane by a function of the respective height and a magnification for the focal region, the magnification varying across the shoulder region in accordance with a drop-off function; a module that is executable on the processor for rotating each displaced point toward a viewpoint for the region-of-interest to maintain visibility of each displaced point; and a module that is executable on the processor for adjusting each rotated point corresponding to the shoulder region to provide a smooth transition to the data representation beyond the lens bounds.
 11. The system of claim 10 and further comprising a module for projecting each adjusted point within the shoulder region, each rotated point within the focal region, and each point of the representation beyond the lens bounds onto a plane in a direction aligned with the viewpoint to produce the presentation.
 12. The system of claim 11 and further comprising a module for displaying the presentation on the display screen.
 13. The system of claim 12 wherein the module for translating each point further comprises a module for determining a maximum translation for a point on the lens bounds and for determining a translation for each point within the lens bounds by scaling the maximum translation in accordance with a distance of each point from the lens bounds.
 14. The system of claim 12 wherein the function is a product of the magnification and a difference between a magnitude of a vector defined by an origin of the representation with respect to the base plane and the viewpoint and the respective height.
 15. The system of claim 12 wherein the module for rotating each displaced point further comprises a module for determining an axis of rotation for the rotating from a cross product of a vector defined by an origin of the representation with respect to the base plane and the viewpoint and a vector defined by the origin and the apex.
 16. The system of claim 12 wherein the module for adjusting each rotated point corresponding to the shoulder region further comprises a module for adding to each rotated point a weighted average of first and second difference vectors scaled by the drop-off function, the first and second difference vectors corresponding to a difference between first and seconds points on the lens bound and corresponding first and second displaced points, respectively, the first and second points being on a line drawn through the rotated point.
 17. The system of claim 10 and further comprising a module for approximating the representation with a mesh.
 18. The system of claim 10 and further comprising a module for approximating the respective height using height information from surrounding points.
 19. One or more tangible computer-readable media having stored thereon, computer-executable instructions that, if executable by a data processing system, cause the data processing system to perform a method comprising: translating each point of a terrain data representation within a lens bounds of a presentation of a region-of-interest, for display on a display screen, to a rotated plane being normal to a vector defined by a position for the region-of-interest with respect to a base plane for the representation and an apex above the base plane, the lens bounds defining a shoulder region at least partially surrounding a focal bounds defining a focal region in which the position is located, each point having a respective height above the base plane; displacing each translated point from the rotated plane by a function of the respective height and a magnification for the focal region, the magnification varying across the shoulder region in accordance with a drop-off function; rotating each displaced point toward a viewpoint for the region-of-interest to maintain visibility of each displaced point; and adjusting each rotated point corresponding to the shoulder region to provide a smooth transition to the data representation beyond the lens bounds.
 20. The tangible computer-readable media of claim 19 and further comprising projecting each adjusted point within the shoulder region, each rotated point within the focal region, and each point of the representation beyond the lens bounds onto a plane in a direction aligned with the viewpoint to produce the presentation.
 21. The tangible computer-readable media of claim 20 and further comprising displaying the presentation on the display screen.
 22. The tangible computer-readable media of claim 21 wherein the translating of each point further comprises determining a maximum translation for a point on the lens bounds and determining a translation for each point within the lens bounds by scaling the maximum translation in accordance with a distance of each point from the lens bounds.
 23. The tangible computer-readable media of claim 21 wherein the function is a product of the magnification and a difference between a magnitude of a vector defined by an origin of the representation with respect to the base plane and the viewpoint and the respective height.
 24. The tangible computer-readable media of claim 21 wherein the rotating of each displaced point further comprises determining an axis of rotation for the rotating from a cross product of a vector defined by an origin of the representation with respect to the base plane and the viewpoint and a vector defined by the origin and the apex.
 25. The tangible computer-readable media of claim 21 wherein the adjusting of each rotated point corresponding to the shoulder region further comprises adding to each rotated point a weighted average of first and second difference vectors scaled by the drop-off function, the first and second difference vectors corresponding to a difference between first and seconds points on the lens bound and corresponding first and second displaced points, respectively, the first and second points being on a line drawn through the rotated point.
 26. The tangible computer-readable media of claim 19 and further comprising approximating the representation with a mesh.
 27. The tangible computer-readable media of claim 19 and further comprising approximating the respective height using height information from surrounding points.
 28. A method comprising: translating with at least one processor, data within a bounds of a lens from a base plane to a rotated plane to form translated data, wherein the bounds of the lens defines a shoulder region at least partially surrounding a focal region; and displacing the translated data along an axis perpendicular to the rotated plane to form displaced data.
 29. The method of claim 28, wherein the axis perpendicular to the rotated plane comprises a vector between: a lens position of the lens, and an apex of a viewing volume including the lens.
 30. The method of claim 29, wherein the translated data is displaced to form the displaced data by an amount determined according to: a magnification of the focal region of the lens; and a vector between: an origin of the viewing volume, and a view reference point.
 31. The method of claim 28, further comprising rotating the displaced data to form rotated data.
 32. The method of claim 31, wherein the displaced data is rotated towards a view reference point to form the rotated data.
 33. The method of claim 32, wherein the displaced data is rotated by a rotation angle to form the rotated data; and wherein the rotation angle is proportional to an angle formed by: a vector between an apex and an origin of a viewing volume including the lens, and a vector between the view reference point and the origin of the viewing volume.
 34. The method of claim 31, further comprising adjusting the shoulder region of the rotated data to provide a smooth transition between the data within the bounds of the lens and data beyond the bounds of the lens.
 35. A system comprising: one or more processors configured to: translate data within a bounds of a lens from a base plane to a rotated plane to form translated data, wherein the bounds of the lens defines a shoulder region at least partially surrounding a focal region; and displace the translated data along an axis perpendicular to the rotated plane to form displaced data.
 36. The system of claim 35, wherein the axis perpendicular to the rotated plane comprises a vector between: a lens position of the lens, and an apex of a viewing volume including the lens.
 37. The system of claim 35, wherein the one or more processors are configured to displace the translated data by an amount determined according to: a magnification of the focal region of the lens; and a vector between: an origin of a viewing volume including the lens, and a view reference point.
 38. The system of claim 35, wherein the one or more processors are configured to rotate the displaced data to form rotated data.
 39. The system of claim 38, wherein the one or more processors are configured to rotate the displaced data towards a view reference point to form the rotated data.
 40. The system of claim 38, wherein the one or more processors are configured to adjust the shoulder region of the rotated data to provide a smooth transition between the data within the bounds of the lens and data beyond the bounds of the lens.
 41. At least one non-transitory computer-readable medium including instructions for execution on one or more processors, wherein the instructions comprise: translation instructions configured to translate data within a bounds of a lens from a base plane to a rotated plane to form translated data, wherein the bounds of the lens defines a shoulder region at least partially surrounding a focal region; and displacement instructions configured to displace the translated data along an axis perpendicular to the rotated plane to form displaced data.
 42. The at least one non-transitory computer-readable medium of claim 41, wherein the axis perpendicular to the rotated plane comprises a vector between: a lens position of the lens, and an apex of a viewing volume including the lens.
 43. The at least one non-transitory computer-readable medium of claim 41, wherein the displacement instructions are configured to displace the translated data by an amount determined according to: a magnification of the focal region of the lens; and a vector between: an origin of a viewing volume including the lens, and a view reference point.
 44. The at least one non-transitory computer-readable medium of claim 41, wherein the instructions comprise rotation instructions configured to rotate the displaced data to form rotated data.
 45. The at least one non-transitory computer-readable medium of claim 44, wherein the rotation instructions are configured to rotate the displaced data towards a view reference point to form the rotated data.
 46. The at least one non-transitory computer-readable medium of claim 45, wherein the rotation instructions are configured to rotate the displaced data by a rotation angle to form the rotated data; and the rotation angle is proportional to an angle formed by: a vector between an apex and an origin of a viewing volume including the lens, and a vector between the view reference point and the origin of the viewing volume.
 47. The at least one non-transitory computer-readable medium of claim 44, wherein the instructions comprise adjustment instructions configured to adjust the shoulder region of the rotated data to provide a smooth transition between the data within the bounds of the lens and data beyond the bounds of the lens. 